<%- include("common/header.ejs") %>
    <%- include("common/nav.ejs")%>
        <div class="container">
            <h1>今日待办</h1>
            <ul class="list-group">
                <% for(let i=0;i<data.length;i++){ %>
                    <li class="list-group-item">
                        <a href="/content?id=<%=data[i].id%>"><%=data[i].title%></a>
                    </li>
                    <% } %>
            </ul>
            <form action="/add" method="POST" role="form">
                <legend>添加待办事项</legend>
                <div class="form-group">
                    <label for="">标题</label>
                    <input type="text" class="form-control" name="title" placeholder="标题">
                </div>
                <div class="form-group">
                    <label for="">内容</label>
                    <input type="text" class="form-control" name="content" placeholder="内容">
                </div>
                <button type="submit" class="btn btn-primary">添加</button>
            </form>

        </div>

        
        
        
        
    <%- include("common/footer.ejs") %>